<div>
    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <h5>查询条件</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-link btn-sm" style="margin-right:10px;"
                                v-on:click="_moreCondition()">{{staffInfo.moreCondition == true?'隐藏':'更多'}}
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <div class="row">
                        <div class="col-sm-4">
                            <div class="form-group ">
                                <select class="custom-select" v-model="staffInfo.conditions.branchOrgId">
                                    <option selected value="">必填，请选择分公司</option>
                                    <option v-for="branchOrg in staffInfo.branchOrgs" :value="branchOrg.orgId">
                                        {{branchOrg.orgName}}
                                    </option>
                                </select>
                            </div>
                        </div>
                        <div class="col-sm-4">
                            <div class="form-group">
                                <select class="custom-select" v-model="staffInfo.conditions.departmentOrgId">
                                    <option selected value="">必填，请选择部门</option>
                                    <option v-for="departmentOrg in staffInfo.departmentOrgs"
                                            :value="departmentOrg.orgId">
                                        {{departmentOrg.orgName}}
                                    </option>
                                </select>
                            </div>
                        </div>
                        <div class="col-sm-3">
                            <div class="form-group">
                                <input type="text" placeholder="请输入员工名称" v-model="staffInfo.conditions.name"
                                       class=" form-control">
                            </div>
                        </div>

                        <div class="col-sm-1">
                            <button type="button" class="btn btn-primary btn-sm" v-on:click="_queryStaffMethod()">
                                <i class="fa fa-search"></i> 查询
                            </button>
                        </div>
                    </div>
                    <div class="row">
                        <div class="col-sm-4" v-if="staffInfo.moreCondition == true">
                            <div class="form-group">
                                <input type="number" placeholder="请输入手机号" v-model="staffInfo.conditions.tel"
                                       class=" form-control">
                            </div>
                        </div>
                        <div class="col-sm-4" v-if="staffInfo.moreCondition == true">
                            <div class="form-group">
                                <input type="number" placeholder="请输入员工ID" v-model="staffInfo.conditions.staffId"
                                       class=" form-control">
                            </div>
                        </div>
                    </div>


                </div>
            </div>
        </div>
    </div>


    <div class="row">
        <div class="col-lg-12">
            <div class="ibox ">
                <div class="ibox-title">
                    <h5>员工管理</h5>
                    <div class="ibox-tools" style="top:10px;">
                        <button type="button" class="btn btn-primary btn-sm" v-on:click="_openAddStaffStepPage()">添加员工
                        </button>
                    </div>
                </div>
                <div class="ibox-content">
                    <table class="footable table table-stripped toggle-arrow-tiny" data-page-size="15">
                        <thead>
                        <tr>
                            <th>员工ID</th>
                            <th>名称</th>
                            <th>公司</th>
                            <th>部门</th>
                            <th>邮箱</th>
                            <th>地址</th>
                            <th>性别</th>
                            <th>手机号</th>
                            <th  class="text-right">操作</th>
                        </tr>
                        </thead>
                        <tbody>
                        <tr class="gradeX" v-for="staff in staffData">
                            <td>{{staff.userId}}</td>
                            <td>{{staff.name}}</td>
                            <td>{{staff.parentOrgName}}</td>
                            <td>{{staff.orgName}}</td>
                            <td>{{staff.email}}</td>
                            <td>{{staff.address}}</td>
                            <td>{{staff.sex == 0 ? '男' : '女'}}</td>
                            <td>{{staff.tel}}</td>

                            <td  class="text-right">
                                <div class="btn-group">
                                    <button class="btn-white btn btn-xs" v-on:click="openEditStaff(staff)">修改
                                    </button>
                                </div>
                                <div class="btn-group">
                                    <button class="btn-white btn btn-xs" v-on:click="_resetStaffPwd(staff)">重置密码
                                    </button>
                                </div>
                                <div v-if="staff.relCd != 600311000001" class="btn-group">
                                    <button class="btn-white btn btn-xs" v-on:click="openDeleteStaff(staff)">删除
                                    </button>
                                </div>
                            </td>
                        </tr>
                        </tbody>
                    </table>
                    <!-- 分页 -->
                    <vc:create path="frame/pagination"></vc:create>

                </div>
            </div>
        </div>
    </div>

    <vc:create path="frame/resetStaffPwd"></vc:create>
    <vc:create path="frame/editStaff"></vc:create>
    <vc:create path="frame/deleteStaff"></vc:create>
</div>